package com.github.gaojh.ioc;


import com.github.gaojh.ioc.bean.FlyingIoc;
import com.github.gaojh.ioc.bean.Ioc;


/**
 * <p>
 *
 * </p>
 *
 * @author gaojh
 * @since 2020/3/20
 */
public class IocUtil {

    private static Ioc ioc = new FlyingIoc();

    public static void addBean(Object object) {
        ioc.addBean(object);
    }

    public static void addBean(String name, Object object) {
        ioc.addBean(name, object);
    }

    public static Object getBean(String name) {
        return ioc.getBean(name);
    }

    public static <T> T getBean(Class<T> clazz) {
        return ioc.getBean(clazz);
    }

}
